package com.hu.network.http.request.method;

import com.hu.network.http.request.method.base.BaseHttpMethod;
import okhttp3.Request;
import okhttp3.RequestBody;

/**
 * 说明：
 *
 * @author ： hucanhua
 * @date ： 2017/10/26
 */
public class PostMethod extends BaseHttpMethod {
    private RequestBody requestBody;

    public PostMethod(String tag, String url, RequestBody requestBody) {
        super(tag, url);
        this.requestBody = requestBody;
    }

    @Override
    protected Request buildRequest() {
        return new Request.Builder()
                .tag(tag)
                .url(url)
                .post(requestBody)
                .build();
    }
}
